package com.manifold.test;

import com.manifold.test.dao.entity.AccountConfirm;
import com.manifold.test.dao.entity.AccountConfirmKey;
import com.manifold.test.dao.mapper.AccountConfirmMapper;
import com.manifold.test.dao0.entity.FundOrder;
import com.manifold.test.dao0.mapper.FundOrderMapper;
import org.apache.commons.lang3.time.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.web.servlet.ServletComponentScan;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.Date;

/**
 * @author shadow
 */
@Controller
@ServletComponentScan
@SpringBootApplication
public class App {
    @Autowired
    private FundOrderMapper fundOrderMapper;
    @Resource
    private AccountConfirmMapper accountConfirmMapper;

    @GetMapping("test")
    FundOrder test() {
        return fundOrderMapper.findById("2015092500000152");
    }

    public static void main(String[] args) throws Exception {
        SpringApplication app = new SpringApplication(App.class);
        app.run(args);
        Date time = DateUtils.parseDate("2017-02-23 10:59:59.500", "yyyy-MM-dd HH:mm:ss.SSS");
        System.out.println("app start..." + time.getTime());
    }
}